package cc.xuzhi.muggle.common.exception;

public class ServiceException extends RuntimeException implements IException {
    private Integer code;

    public ServiceException(Integer code, String message) {
        this(code, message, null);
        this.code = code;
    }

    public ServiceException(Integer code, String message, Throwable e) {
        super(message, e);
        this.code = code;
    }

    @Override
    public Integer getCode() {
        return code;
    }

    @Override
    public String getMessage(){
        return super.getMessage();
    }

}
